package Component;


public abstract class ComponentDecorator implements IComponent {
    protected IComponent component;

    public ComponentDecorator(IComponent component) {
        this.component = component;
    }

    @Override
    public void display() {
        if (component != null) {
            component.display();
        }
    }
}
